package com.zzzy.doc.dao.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Getter;
import lombok.Setter;

import java.time.LocalDateTime;

/**
 * 单位收文记录
 *
 * @author fc
 * @since 2024-09-09
 */
@Getter
@Setter
@TableName("doc_receive_record")
@Schema(description = "单位收文记录")
public class DocReceiveRecord {

    @Schema(description = "ID")
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @Schema(description = "发文记录ID")
    @TableField("send_record_id")
    private Long sendRecordId;

    @Schema(description = "公文ID")
    @TableField("doc_id")
    private Long docId;

    @Schema(description = "收文单位ID")
    @TableField("receive_dept_id")
    private Long receiveDeptId;

    @Schema(description = "收文用户ID")
    @TableField("receive_user_id")
    private Long receiveUserId;

    @Schema(description = "收文用户姓名")
    @TableField("receive_user_name")
    private String receiveUserName;

    @Schema(description = "公文来源：主送、抄送")
    @TableField("receive_source")
    private String receiveSource;

    @Schema(description = "状态：待签收、已签收")
    @TableField("`status`")
    private String status;

    @Schema(description = "收文时间")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @TableField("receive_time")
    private LocalDateTime receiveTime;

    @Schema(description = "签收时间")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @TableField("confirm_receive_time")
    private LocalDateTime confirmReceiveTime;
}
